export interface SearchDataType {
  type: "input" | "select" | "radio";
  label: string;
  value?: any;
  options?: Array<{ label: string; value: string | number }>;
}

// 企发销售属性
export const SalesSearchData: Record<string, SearchDataType> = {
  prop_id: {
    type: "input",
    label: "属性ID"
  },
  property_cn: {
    type: "input",
    label: "属性名称(中文)"
  },
  property: {
    type: "input",
    label: "属性名称(俄文)"
  },
  property_en: {
    type: "input",
    label: "属性名称(英文)"
  },
  prop_type: {
    type: "select",
    label: "属性类型"
  },
  prop_sort_filter: {
    type: "input",
    label: "筛选栏排序"
  },
  prop_sort_detail: {
    type: "input",
    label: "商品详情页排序"
  },
  sort_prop_detail_focal: {
    type: "input",
    label: "详情页重点排序"
  },
  prop_group: {
    type: "select",
    label: "属性分组"
  },
  prop_group_sort: {
    type: "input",
    label: "后台属性分组排序"
  },
  is_required: {
    type: "radio",
    label: "是否必填",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  },
  is_spec: {
    type: "radio",
    label: "是否规格",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  },
  is_number: {
    type: "radio",
    label: "是否数值类型",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  },
  un_editable_checked: {
    type: "radio",
    label: "审核后无法编辑",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  },
  display_filter: {
    type: "radio",
    label: "筛选栏是否展示",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  },
  display_detail: {
    type: "radio",
    label: "详情页是否展示",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  },
  display_detail_focal: {
    type: "radio",
    label: "详情页是否重点展示",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  },
  is_search: {
    type: "radio",
    label: "是否参与搜索",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  },
  for_sku: {
    type: "radio",
    label: "货号属性",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  }
};

// 清关属性
export const ClearanceData: Record<string, SearchDataType> = {
  cc_prop_id: {
    type: "input",
    label: "清关属性ID"
  },
  cc_property_cn: {
    type: "input",
    label: "清关属性名称(中文)"
  },
  cc_property: {
    type: "input",
    label: "清关属性名称(俄文)"
  },
  cc_property_en: {
    type: "input",
    label: "清关属性名称(英文)"
  },
  cc_prop_type: {
    type: "select",
    label: "清关属性类型"
  },
  sort: {
    type: "input",
    label: "排序"
  },
  cc_prop_group: {
    type: "select",
    label: "清关属性分组"
  },
  cc_prop_group_sort: {
    type: "input",
    label: "清关属性分组排序"
  },
  cc_is_required: {
    type: "radio",
    label: "是否必填",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  },
  is_spec: {
    type: "radio",
    label: "是否规格",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  },
  un_editable_checked: {
    type: "radio",
    label: "审核后无法编辑",
    options: [
      { value: 1, label: "是" },
      { value: 0, label: "否" }
    ]
  }
};
